#!/usr/bin/python3.8.9
# -*- coding: utf-8 -*-

# @Author  : Tina Yu
# @Time    : 2021-7-24 22:41
import pygame


class Bird:
    """管理和平鸽的类"""

    def __init__(self, bird_game):
        """初始化初始位置"""
        self.screen = bird_game.screen
        self.screen_rect = bird_game.screen.get_rect()

        # 加载和平鸽图像并获取其外接矩阵
        self.image = pygame.image.load('bird.bmp')
        self.rect = self.image.get_rect()

        # 放置在底部中间
        self.rect.midbottom = self.screen_rect.midbottom

    def blitme(self):
        """在指定位置绘制和平鸽"""
        self.screen.blit(self.image, self.rect)
